package com.qf.dao.impl;

import com.qf.dao.AccountDao;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Repository;

import javax.annotation.PostConstruct;
import javax.annotation.PreDestroy;


@Repository
@Scope("prototype")
public class AccountDaoImpl implements AccountDao {
    public AccountDaoImpl() {
        System.out.println("accountdao的无参构造");
    }

    public void addAccount() {
        System.out.println("新增账户执行。。。。");
    }

    @PostConstruct  //构造对象初始化之后执行
    public void init(){
        System.out.println("accoutdao的初始化方法");
    }
    @PreDestroy  //容器销毁的时候执行
    public void destory(){
        System.out.println("accountdao的销毁方法");
    }
}
